package com.spring.design.builder;

/**
 * 指挥者
 */
public class Director {

    Builder builder=null;

    public Director(Builder builder) {
        this.builder = builder;
    }

    public void setConcreteBuilder(Builder builder) {
        this.builder = builder;
    }

    //建造房子交给指挥者
    public Product couPro(){
        builder.builderBisic();
        builder.ilderWalls();
        builder.roofed();
        return builder.build();
    }

}
